home *** CD-ROM | disk | FTP | other *** search
Wrap
<?xml version="1.0" encoding="utf-8"?> <html><head><title>Red Function [Runtime]</title><meta name="filename" content="text/sbasic/common/03010303"/><meta name="language" content="en-US"/><help:css-file-link xmlns:help="http://openoffice.org/2000/help"/><!--The CSS style header method for setting styles--><style type="text/css"> p.P1{ } p.P2{ } span.T1{ font-weight:bold;} </style></head><body> <help:to-be-embedded Eid="red" xmlns:help="http://openoffice.org/2000/help"> <p class="Head1"><help:link Id="66385">Red Function [Runtime]</help:link></p> <p class="Paragraph">Returns the Red component of the specified color code.</p> </help:to-be-embedded> <p class="Paragraph"><span class="T1">Syntax</span>:</p> <p class="Paragraph">Red (ColorNumber As Long) <help:key-word value="Red" tag="kw66385_1" xmlns:help="http://openoffice.org/2000/help"/></p> <p class="Paragraph"><span class="T1">Return value</span>:</p> <p class="Paragraph">Integer</p> <p class="Paragraph"><span class="T1">Parameter</span>:</p> <p class="Paragraph">ColorNumber: Long integer expression that specifies any <help:popup Id="66475" Eid="farbcodes" xmlns:help="http://openoffice.org/2000/help">color code</help:popup> for which to return the Red component.</p> <p class="P2">Example:</p> <p class="PropText">Sub ExampleColor</p> <p class="PropText">Dim lVar As Long</p> <p class="PropText">lVar = rgb(128,0,200)</p> <p class="PropText">msgbox "The color " & lVar & " consists of:" & Chr(13) &_</p> <p class="PropText">"red= " & <text:s text:c="" xmlns:text="http://openoffice.org/2000/text"/>red(lVar) & Chr(13)&_</p> <p class="PropText">"green= " & <text:s text:c="" xmlns:text="http://openoffice.org/2000/text"/>green(lVar) & Chr(13)&_</p> <p class="PropText">"blue= " & <text:s text:c="" xmlns:text="http://openoffice.org/2000/text"/>blue(lVar) & Chr(13) , 64,"colors"</p> <p class="PropText">end sub</p> <p class="PropText"/> </body></html>